package com.gxy.learn.design.model.behaviour.state;

/**
 * @description: 状态模式测试
 * @author: gaoxueyong
 * @Date: 2022/11/8 16:38
 */
public class Client {
    public static void main(String[] args) {
//        创建环境角色对象
        Context context = new Context();
//        这种当前电梯状态
//        context.setLiftState(new RunningState());
        context.setLiftState(new ClosingState());
        context.open();
        context.close();
        context.run();
        context.stop();
    }
}
